package com.example.aiinterview.repository;

import com.example.aiinterview.model.ChatMessage;
import com.example.aiinterview.model.Interview;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface ChatMessageRepository extends JpaRepository<ChatMessage, Long> {
    List<ChatMessage> findByInterviewOrderByTimestampAsc(Interview interview);
    List<ChatMessage> findByInterviewIdOrderByTimestampAsc(Long interviewId);
}
